package lowijs.XfireClient;

import java.util.*;

public class IM {
	private long channelid;

	private long userid;

	private String user;

	private String msg;

	private byte[] sid;

	private int imindex;

	private Date date;

	public IM(long channelid, long userid, String user, String msg, byte[] sid, int imindex) {
		if (channelid < 1) {
			throw new IllegalArgumentException("Bad Channel " + channelid);
		}

		this.channelid = channelid;
		this.userid = userid;
		this.user = user;
		this.msg = msg;
		this.sid = sid;
		this.imindex = imindex;

		this.date = new Date();
	}

	public long getChannelid() {
		return channelid;
	}

	public long getUserid() {
		return userid;
	}

	public String getUser() {
		return user;
	}

	public String getMessage() {
		return msg;
	}

	public Date getDate() {
		return date;
	}

	public byte[] getSid() {
		return sid;
	}

	public int getImindex() {
		return imindex;
	}
}
